<template>
  <div id="important_info">
    <h2>{{homeTitle}}</h2>
      <ul class="important_info_body">
        <li v-for="(item,index) of bookList" :key="index">
          <img :src="item.bookCover" />
          <div class="book_message">{{item.bookMessage}}</div>
        </li>
      </ul>
  </div>
</template>

<script>
export default {
  name: "ImportantInfo",
  props:{
    homeTitle:{
      type:String,
    }
  },
  data(){
    return{
      bookList:[
        {
          bookCover:"http://img3m3.ddimg.cn/23/25/29311943-1_u_9.jpg",
          bookMessage:"《活着》定本·2021版"
        },
        {
          bookCover:"http://img3m5.ddimg.cn/61/17/29305645-1_u_5.jpg",
          bookMessage:"人间词话"
        },
        {
          bookCover:"http://img3m3.ddimg.cn/70/8/25216063-1_u_20.jpg",
          bookMessage:"诗经"
        },
      ]
    }
  }
}
</script>

<style scoped>
#important_info{
  position: absolute;
  width: 100%;
  height: 300px;
  /*background: pink;*/
  transform: translateY(-70%);
  z-index: 5;
}
h2{
  color: #ffffff;
  font-size: 40px;
  text-align: right;
  text-shadow: 3px 5px 4px #000;
  padding-right: 100px;
  font-weight: 400;
  font-family: '苏新诗柳楷简';
}
.important_info_body{
  position: relative;
  display: flex;
  margin: 20px auto;
  width: 65%;
  /*height: 200px;*/
  text-align: center;
}
.important_info_body li{
  flex: 1;
  padding: 10px;
  margin: 0 10px;
  border-bottom: 5px solid transparent;
  transition: all 500ms;
}
.important_info_body li:hover{
  cursor: pointer;
  border-bottom: 5px solid hotpink;
}
.important_info_body li img{
  width: 80%;
  min-width: 150px;
}
.book_message{
  width: 100%;
  font-size: 20px;
  text-overflow: ellipsis;
  overflow: hidden;
  text-overflow: ellipsis;
}

</style>
